#添加

list_one = [1, 2, 3, 4]
list_one.append(5)
print(list_one)

list_str = ['a', 'b', 'c']
list_num = [1, 2, 3]
list_str.extend(list_num)
print(list_num)
print(list_str)

names = ['baby', 'lucy', 'Alise']
names.insert(2, 'Peter')
print(names)

#删除

names = ['小明', '小红', '小华', '小花', '小李', '小张']
del names[0]
print(names)
del names[1:3]
print(names)

chars = ['h', 'e', 'l', 'l', 'e']
chars.remove('e')
print(chars)

numbers = [1, 2, 3, 4, 5]
numbers.pop()
print(numbers)
numbers.pop(1)
print(numbers)

#修改

names = ['小明', '小红', '小华']
names[0] = '小花'
print(names)
